Geo-fencing in a building automation system

ABSTRACT

A mobile device having location services may store information pertaining to a geo-fence that is associated with a user of the mobile device and assigned to a location. The mobile device may identify a current location of the mobile device and store data pertaining to the location of the mobile device. The mobile device determines a current geo-fence state of the mobile device based on the location data in response to an internal stimuli or an external stimuli. The geo-fence state is selected from at least an inside geo-fence state in which the mobile device is deemed to be inside the geo-fence and an outside geo-fence state in which the mobile device is deemed to be outside of the geo-fence. The mobile device may notify a remote server of the current geo-fence state.

This application is a continuation of co-pending U.S. patent application Ser. No. 14/668,800, filed Mar. 25, 2015, entitled, “GEO-FENCING IN A BUILDING AUTOMATION SYSTEM,” which is incorporated herein by reference.

TECHNICAL FIELD

The disclosure relates generally to building automation, and more particularly to building automation systems with geo-fencing capabilities.

BACKGROUND

Building automation systems are often used to control safety, security and/or comfort levels within a building or other structure. Illustrative but non-limiting examples of building automation systems include Heating, Ventilation and/or Air Conditioning (HVAC) systems, security systems, lighting systems, fire suppression systems and/or the like. In some cases, a building automation system may enter an unoccupied mode when the building is expected to be unoccupied and an occupied mode when the building is expected to be occupied. For example, when the building automation system includes an HVAC system, the building automation system may set a temperature set point of the HVAC system to a more energy efficient setting when in an unoccupied mode and a more comfortable setting when in an occupied mode. In another example, when the building automation system includes a security system, the building automation system may set the security system to a locked or away state when in an unoccupied mode and an unlocked or home state when in an occupied mode.

SUMMARY

The present disclosure pertains generally to geo-fencing, and more particularly to improvements in the accuracy and robustness of geo-fencing. An example of the disclosure may be found in a non-transitory computer-readable storage medium with an executable program stored thereon. The executable program may instruct a mobile device having location services to store information pertaining to a geo-fence associated with the user of the mobile device and assigned to a particular building or location. The executable program may instruct the mobile device to identify a current location of the mobile device via location services, and store location data that includes the current location of the mobile device and one or more past locations of the mobile device. The executable program may instruct the mobile device to determine a current geo-fence state (e.g. inside the geo-fence or outside the geo-fence) of the mobile device based on the location data, sometimes in response to an internal stimuli or an external stimuli. The executable program may instruct the mobile device to notify a remote server of the current geo-fence state, sometimes automatically and/or on-demand.

Another example of the disclosure may be found in a building automation server for servicing a user's building. The building automation server may include an input for receiving a geo-fence state of one or more mobile devices, and an output for outputting a command to a building controller in the user's building. The building automation server may include a controller operably coupled to the input and the output. The controller may be configured to maintain a current geo-fence state for each of the one or more mobile devices based on the geo-fence state received from each of the one or more mobile devices. The controller may be further configured to output a command via the output to change a set point of the building controller to an energy saving set point upon detection that all of the one or more mobile devices associated with a building are in an outside geo-fence state, and to output a command via the output to change the set point of the building controller to a comfort set point upon detecting of all of the one or more mobile devices associated with the building are not in the outside geo-fence state. The controller may be further configured to not send a new command to change the set point of the building controller if the received geo-fence state of the one or more mobile devices associated with the building would not result in the controller outputting a different command than the previous command that was output by the controller by the controller.

Another example of the disclosure may be found in a mobile device having location services. The mobile device may include a user interface, a memory and a controller. The controller may be configured to check the location of the mobile device via the location services of the mobile device and to compare a current detected location relative to a stored geo-fence with a previously detected location relative to the stored geo-fence.

In some cases, the controller may check the location of the mobile device relative to the geo-fence from time to time, or in response to an internal stimuli. The internal stimuli may include, for example: detecting a restoration of a cellular service to the mobile device; detecting a restoration of an internet service to the mobile device; detecting a restoration of the location services of the mobile device; detecting a user logging into an executable program on the mobile device; detecting a wake up condition from a force close of an executable program on the mobile device; detecting the mobile device exiting an airplane mode; detecting a power on condition of the mobile device; detecting an updated geo-fence; detecting a new location and associated geo-fence; detecting that geo-fencing was turned on, and/or any other suitable internal stimuli.

In some cases, the controller may check the location of the mobile device relative to the geo-fence in response to an external stimuli. The external stimuli may include, for example: the mobile device being informed that a suspend mode of the geo-fence has been turned off at a remote location; the mobile device being informed that the geo-fence has been modified at a remote location; the mobile device being informed that another user has crossed the geo-fence; the mobile device being informed that the geo-fence state of another user has changed or that another user has turned geo-fencing on or off on their mobile device; the mobile device receiving a request for a current location from a remote location, and/or any other suitable external stimuli.

After checking the location of the mobile device, the controller may be configured to provide a remote server with the current detected location relative to the geo-fence if the current detected location relative to the geo-fence is different from the previously detected location relative to the geo-fence. The controller may be further configured to not provide the remote server with the current detected location relative to the geo-fence if the current detected location relative to the geo-fence is the same as the previously detected location relative to the geo-fence.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a schematic view of an illustrative building automation system;

FIG. 2 is a schematic view of another illustrative building automation system;

FIG. 3 is a schematic view of another illustrative building automation system;

FIG. 4 is a schematic view of an illustrative building automation server;

FIG. 5 is a schematic view of an illustrative mobile device;

FIG. 6 is a flow diagram showing an illustrative method that may be carried out by the mobile device of FIG. 5; and

FIG. 7 is a flow diagram showing another illustrative method that may be carried out by the mobile device of FIG. 5.

While the disclosure is amenable to various modifications and alternative forms, specifics thereof have been shown by way of example in the drawings and will be described in detail. It should be understood, however, that the intention is not to limit aspects of the disclosure to the particular illustrative embodiments described. On the contrary, the intention is to cover all modifications, equivalents, and alternatives falling within the spirit and scope of the disclosure.

DESCRIPTION

The following description should be read with reference to the drawings wherein like reference numerals indicate like elements. The drawings, which are not necessarily to scale, are not intended to limit the scope of the disclosure. In some of the figures, elements not believed necessary to an understanding of relationships among illustrated components may have been omitted for clarity.

All numbers are herein assumed to be modified by the term “about”, unless the content clearly dictates otherwise. The recitation of numerical ranges by endpoints includes all numbers subsumed within that range (e.g., 1 to 5 includes 1, 1.5, 2, 2.75, 3, 3.80, 4, and 5).

As used in this specification and the appended claims, the singular forms “a”, “an”, and “the” include the plural referents unless the content clearly dictates otherwise. As used in this specification and the appended claims, the term “or” is generally employed in its sense including “and/or” unless the content clearly dictates otherwise.

It is noted that references in the specification to “an embodiment”, “some embodiments”, “other embodiments”, etc., indicate that the embodiment described may include a particular feature, structure, or characteristic, but every embodiment may not necessarily include the particular feature, structure, or characteristic. Moreover, such phrases are not necessarily referring to the same embodiment. Further, when a particular feature, structure, or characteristic is described in connection with an embodiment, it is contemplated that the feature, structure, or characteristic may be applied to other embodiments whether or not explicitly described unless clearly stated to the contrary.

The present disclosure is directed generally at building automation systems. Building automation systems are systems that control one or more operations of a building. Building automation systems can include HVAC systems, security systems, fire suppression systems, energy management systems and/or any other suitable systems. While HVAC systems are used as an example below, it should be recognized that the concepts disclosed herein can be applied to building control systems more generally.

A building automation system may include a controller, computer and/or other processing equipment that is configured to control one or more features, functions, systems or sub-systems of a building. In some cases, devices that can be used by individuals to communicate with the controller, computer and/or other processing equipment. In some cases, a building automation system may include a plurality of components that, in combination, perform or otherwise provide the functionality of the building automation system. A building automation system may be fully contained within a single building, or may include components that are spread between multiple housings and/or across multiple locations. In some embodiments, a building automation system, regardless of the physical location(s) of the components within the building automation system, may control one or more building systems within a single building. In some cases, a building automation system, regardless of the physical location(s) of the components within the building automation system, may control one or more building systems within a plurality of buildings, optionally in accordance with a common operating procedure and/or distinct operating procedures for each building as desired.

FIG. 1 is a schematic illustration of an illustrative building automation system 10. The illustrative building automation system 10 includes a server 12 that may be configured to communicate with a mobile device 14 and with a building controller 16. It will be appreciated that for simplicity, only a single mobile device 14 is shown, while in many cases the server 12 may be configured to communicate directly or indirectly with any number of mobile devices 14. Similarly, while a single building controller 16 is illustrated, in many cases the server 12 may be configured to communicate directly or indirectly with any number of building controllers 16, located in a single building or distributed throughout a plurality of buildings. The server 12 is illustrated as a single, cloud-based server. In some cases, the server 12 may be a single server. In some instances, the server 12 may generically represent two, three or more servers commonly located or spread between two or more physical locations. In some cases, the server 12 handles communication with both the mobile device 14 and the building controller 16. In some instances, as shown for example in FIG. 2, distinct servers may carry out each communications protocol if desired.

In some cases, the mobile devices 14 may communicate with the server 12 at least partially through a network such as the Internet, sometimes using a cell phone network, WiFi network and/or any other suitable network. Likewise, it is contemplated that the building controller 16 may communicate with the server 12 at least partially through a network such as the Internet, sometimes using a cell phone network, WiFi network and/or any other suitable network.

FIG. 2 is a schematic illustration of another illustrative building automation system 20. The illustrative building automation system 20 includes a first server 22 that may be configured to communicate with a mobile device 14 (or multiple mobile devices 14) and a second server 24 that may be configured to communicate with a building controller 16 (or multiple building controllers 16). The first server 22 may be configured to receive data from the mobile device 14, process the data, and send data to the mobile device 14 and/or to the second server 24. The second server 24 may be configured to receive data from the building controller 16, process the data, and send data to the building controller 16 and/or to the first server 22. In some instances, the first server 22 may be configured to permit data from the mobile device 14 to pass directly through to the building controller 16. In some cases, the second server 24 may be configured to permit data from the building controller 16 to pass directly through to the mobile device 14. The first server 22 and the second server 24 may be configured to communicate with each other. In some cases, each of the first server 22 and the second server 24 may perform a defined function.

It will be appreciated that for simplicity, only a single mobile device 14 is shown, while in many cases the first server 22 may be configured to communicate directly or indirectly with any number of mobile devices 14. Similarly, while a single building controller 16 is illustrated, in many cases the second server 24 may be configured to communicate directly or indirectly with any number of building controllers 16, located in a single building or distributed throughout a plurality of buildings.

The first server 22 is illustrated as a single, cloud-based server. In some cases, the first server 22 may be a single server. In some instances, the first server 22 may generically represent two, three or more servers commonly located or spread between two or more physical locations. The second server 24 is illustrated as a single, cloud-based server. In some cases, the second server 24 may be a single server. In some instances, the second server 24 may generically represent two, three or more servers commonly located or spread between two or more physical locations. In some cases, the first server 22 and the second server 24 may, in combination, be considered as representing or forming a building automation server 26.

FIG. 3 is a schematic illustration of a building automation system 30 in which a building automation server 26 is configured to communicate with a plurality of buildings 32 as well as a plurality of mobile devices 34. It is contemplated that the building automation server 26 may include a single server or two or more distinct servers at one or several locations. The building automation system 30 may serve any desired number of buildings. As illustrated, the plurality of buildings 32 includes a Building One, labeled as 32A, a Building Two, labeled as 32B, and so on through a Building “N”, labeled as 32N. It will be appreciated that the building automation system 30 may include a large number of buildings, each in communication with a central (or distributed) building automation server 26. In some cases, each building may be associated with a unique customer account, as further described below.

As illustrated, each of the plurality of buildings 32 includes a building controller and one or more pieces of building equipment. The building equipment may, for example, be HVAC equipment, security equipment, lighting equipment, fire suppression equipment, and/or the like. In particular, the building 32A includes a building controller 36A and building equipment 38A, the building 32B includes a building controller 36B and building equipment 38B, and so on through the building 32N, which includes a building controller 36N and building equipment 38N. It will be appreciated that while each building is illustrated as having a single building controller and single building equipment controlled by the single building controller, in some cases a building may have multiple related or unrelated building controllers and/or multiple pieces of related or unrelated building equipment.

The plurality of mobile devices 34 may be considered as being divided into a set of mobile devices each associated with a corresponding building. In the example shown, the plurality of mobile devices 34 may be considered as being divided into a set of mobile devices 40A that are associated with the building 32A, a set of mobile devices 40B that are associated with the building 32B, and so on through a set of mobile devices 40N that are associated with the building 32N. As illustrated, the set of mobile devices 40A includes a first mobile device 42A, a second mobile device 44A and a third mobile device 46A. The set of mobile devices 40B includes a first mobile device 42B, a second mobile device 44B and a third mobile device 46B and so on through the set of mobile devices 40N, which includes a first mobile device 42N, a second mobile device 44N and a third mobile device 46N. This is merely illustrative, as any number of mobile devices such as smartphones or tablets, may be associated with a particular building, as desired. Each user or occupant of a building may have an associated mobile device, or may have several associated mobile devices. In some cases, a user or occupant may have a mobile device associated with several different locations such as a home, a cabin or a place of work.

Associating a mobile device with a particular building generally involves the individual who uses the particular mobile device. In the example shown in FIG. 3, a mobile device can communicate with the building automation server 26, and may cause the building automation server 26 to provide instructions to the building controller that is associated with the particular mobile device. For example, and in some instances, a mobile phone with location services activated can be used to inform the building automation server 26 as to the whereabouts of the user relative to a geo-fence defined for the associated building, and in some cases an estimate of how long before the user will arrive at the associated building. The building automation server 26 may send a command to the building controller of the associated building to operate the building equipment in an energy savings manner when all of the users that are associated with a particular building are determined to be away from the building (e.g. the building is unoccupied). The building automation server 26 may send a command to the building controller of the associated building to operate the building equipment in a comfort mode when all of the users that are associated with a particular building are determined or deemed not to be away from the building (e.g. the building is occupied).

In some instances, the building automation server 26 may be configured to maintain a current geo-fence state for each of the one or more mobile devices 14 based on the geo-fence state received from each of the one or more mobile devices. In some cases, the geo-fence state for each of the one or more mobile devices 14, the association between each of the mobile devices and corresponding buildings and as well as other information may be stored in a database that is part of or accessible by the building automation server 26. Example non-limiting databases include MySQL, PostgreSQL, Microsoft SQL Server, Oracle, Sybase and IBM DB2.

FIG. 4 is a schematic illustration of the building automation server 26, as previously referenced in FIGS. 2 and 3. The building automation server 26 may be configured for servicing a user's building, and in some cases other buildings. The building automation server 26 may include an input 50, an output 52 and a controller 54 that is operably coupled to the input 50 and the output 52. The input 50 and the output 52 may take any appropriate physical or electrical form. In some instances, the input 50 may be configured for receiving information regarding a geo-fence state of one or more mobile devices (such as the mobile device 14 shown in FIGS. 1 and 2). In some cases, the geo-fence state may be selected from at least an inside geo-fence state in which a corresponding mobile device 14 is deemed to be inside a geo-fence that is defined for the user's building, and an outside geo-fence state in which the corresponding mobile device 14 is deemed to be outside of the geo-fence that is defined for the user's building. The output 52 may be configured for outputting a command to a building controller in the user's building. For example, the output 52 may be configured to output an away command to the building controller 32 a in Building One (FIG. 3) when the building automation server 26 determines that all of the mobile devices 40 a associated with Building One 32 a are in the outside geo-fence state. Likewise, the output 52 may be configured to output a home command to the building controller 32 a in Building One (FIG. 3) when the building automation server 26 determines that all of the mobile devices 40 a associated with Building One 32 a are not in the outside geo-fence state.

When the building controller is an HVAC controller, the controller 54 may be configured to output a command via the output 52 to change a set point of the building controller to an energy saving set point when the controller 54 detects that the current geo-fence state of all of the one or more mobile devices 14 associated with the building are in the outside geo-fence state. In some cases, the controller 54 may be configured to output a command via the output 52 to change the set point of the building controller to a comfort set point upon detecting that the current geo-fence state of all of the one or more mobile devices 14 associated with the building are not in the outside geo-fence state, i.e., one or more of the mobile devices 14 are in the inside geo-fence state.

In some instances, the controller 54 is configured to not send a new command, such as to change the set point of the building controller, if the received geo-fence state of the one or more mobile devices 14 would not result in a different command being output. For example, if the current geo-fence state of all of the one or more mobile devices 14 were in the outside geo-fence state, with the controller 54 aware of the status of each of the one or more mobile devices 14, and the controller 54 receives an outside geo-fence state from one of the one or mobile devices 14, the controller 54 may be configured to not send a command to the building controller as there is nothing to change. In some cases, the controller 54 will only send a command to the building controller when there is something to change.

In some instances, the controller 54 may be configured to solicit location information from one or more of the mobile devices. For example, the controller 54 may be configured to solicit location information from a particular mobile device 14 if, for example, the controller 54 has not received a geo-fence state for the particular mobile device 14 for a predetermined length of time. In some cases, the controller 54 may solicit location information from a particular mobile device 14 if the controller 54 has not received any location information from that mobile device 14 for a period of time such as one hour, two hours, three hours, four hours, six hours, twelve hours, twenty-four hours, or more or less.

In some cases, the controller 54 may be configured to solicit location information from a particular mobile device 14, or perhaps from each of the one or more mobile devices 14 on a regular, repeating schedule of any desired frequency. In some embodiments, however, the controller 54 may be configured to solicit location information from a particular mobile device 14 at an increased frequency if a geo-fence crossing by the particular mobile device 14 is anticipated. For example, if the controller 54 learns from history that a particular user tends to cross a geo-fence on their way home every weekday between 5 pm and 6 pm, the controller 54 may solicit location information on a more frequent basis each weekday between 5 pm and 6 pm, or perhaps between 4:30 pm and 6:30 pm, or perhaps from 4:30 pm to until a crossing is detected.

In some cases, the controller 54 may be configured to solicit location information of a higher accuracy level from a particular mobile device 14 if a geo-fence crossing by the particular mobile device 14 is anticipated. For example, a low accuracy level request from the controller 54 may cause the mobile device 14 to rely on cell signal strength, triangulation, and/or other option lower power than GPS. Conversely, a high accuracy level request may cause the mobile device 14 to rely on a more accurate but more power-hungry location service such as GPS. In some cases, the controller 54 may be configured to send one of the mobile devices 14 a request to temporarily turn on GPS functionality within the mobile device and to return a GPS location to the controller 54. In some instances, the mobile device may instead return the geo-fence state (in or out) to the controller 54. In some cases, each of the one or more mobile devices 14 do not send an updated geo-fence state to the input 50 unless the geo-fence state of the corresponding mobile device 14 changes. In some instances, each of the one or more mobile devices 14 may send an updated geo-fence state to the input 50 when the geo-fence state of the corresponding mobile device 14 changes.

FIG. 5 is a schematic diagram of the illustrative mobile device 14, as previously referenced in FIGS. 1 and 2. The illustrative mobile device 14 has location services for determining a location of the mobile device 14, and includes a user interface 56, a memory 58 and a controller 60 that is operably coupled to the user interface 56 and to the memory 58. In some cases, the memory 58 may be configured to store information pertaining to a geo-fence assigned to a building, as well as storing an executable program. In some cases, the controller 60 may be configured to check the location of the mobile device via the location services of the mobile device 14 and compare the current detected location relative to the geo-fence with a previously detected location relative to the geo-fence stored in the memory 58. The controller 60 may be configured to provide the remote server 26 with the current detected location relative to the geo-fence if the current detected location relative to the geo-fence is different from the previously detected location relative to the geo-fence. Alternatively, in some cases, the controller 60 may instead return the geo-fence status. In some cases, the controller 60 may not provide the remote server 26 with the current detected location relative to the geo-fence or geo-fence status if the current detected location relative to the geo-fence is the same as the previously detected location relative to the geo-fence or the previous geo-fence status.

In some instances, the controller 60 is configured to check the location of the mobile device relative to the geo-fence from time to time. For example, the controller 60 may check the location of the mobile device each hour or each half hour. In some cases, the controller 60 may check the location of the mobile device relative to the geo-fence in response to an internal stimuli or an external stimuli. A variety of different internal and external stimuli are contemplated. Illustrative but non-limiting examples of internal stimuli include the mobile device 14 detecting a restoration of cellular service and/or a restoration of internet service to the mobile device 14. In some cases, if there is a loss in cellular service or internet service, the mobile device 14 is unable to transmit its geo-fence status. When service is restored, the mobile device 14 can go ahead and transmit its geo-fence status. In some cases, the mobile device 14 may first update its geo-fence status before transmitting its geo-fence status.

Another example internal stimuli may include restoration of the location services of the mobile device 14. If location services has been turned off, either accidently or intentionally, the mobile device 14 will be unable to determine its location. When this is discovered, or the user otherwise turns location services back on, the mobile device 14 may check its location and report its geo-fence status to the remote server 26.

In some cases, if a user is talking on the mobile device 14 during a geo-fence crossing, the mobile device 14 may not be able to report the crossing until after the phone call. In such a case, the mobile device 14 may repeatedly attempt to report the crossing until the crossing is successfully reported or a time limit is reached. In some cases, the time limit is a span of time that begins with termination of the phone call. If attempts to report the crossing repeatedly fail, the user may be informed of this via the user interface 56. For example, if the mobile device 14 is an Android device, and an initial communication attempt with the building automation server 26 fails, the mobile device 14 may try again in thirty seconds, then in one minute, then in two minutes, then in four minutes, then in eight minutes, and then again in thirty minutes. It will be appreciated that these time spans are merely illustrative.

In some instances, the mobile device 14 includes an executable program stored in the memory 58 that governs and controls some of the communication with the building automation server 26. Another example of an internal stimuli is detecting a user logging in to the executable program. This may be a physical login, in which the user enters user name and password, or it may be an auto-login utilizing stored user name and password information. Another example is detecting a wake up condition from a force close of the executable program. The user switching off airplane mode, and powering on the mobile device 14, are other examples of internal stimuli. If the mobile device 14 detects an updated geo-fence, or detects a new location and associated geo-fence, the mobile device 14 may also treat these as internal stimuli.

In some cases, if the executable program detects that the mobile device 14 is in a state in which the mobile device 14 is not able to detect a geo-fence crossing, the executable program may notify the user via the user interface 56 that there is a problem. In some cases, the executable program may also inform the user how to correct the problem. It may, for example, be as simple as turning on location services, or turning geo-fencing on, or exiting airplane mode. In some embodiments, it is contemplated that if possible, the executable program may itself modify settings within the mobile device 14 to correct the problem, perhaps with a notification to the user that an automatic setting change was made.

There are a number of illustrative but non-limiting examples of external stimuli that may cause the controller 60 to check the location of the mobile device relative to the geo-fence. For example, the controller 60 may check the location of the mobile device in response to being informed that a suspend mode of the geo-fence has been turned off at a remote location, such as at a particular building controller, or that another user has turned their geo-fencing on or off. In some embodiments, there may be a desire to instruct the building controller to operate manually (e.g. without geo-fencing), at least for a period of time. While operating manually, the building controller may operate one or more building systems to maintain a particular temperature set point or schedule, a lighting mode, a security system mode, and the like. While operating manually, the building controller may ignore any geo-fence events and/or geo-fence related commands from a building automation server 26. In some instances, the building automation server 26 may keep track of geo-fence events that occur during a period of manual operation resulting from an individual triggering a suspend mode using either the building controller or their mobile device. While geo-fence events may not be transmitted to the building controller, or may be transmitted to the building controller but ignored by the building controller, the building automation server 26 may still use those triggers to update the status of each assigned user.

Other examples of external stimuli may include geo-fencing changes and/or geo-fence events of other users. For example, the mobile device 14 may be informed that the geo-fence has been modified at a remote location, or that another user associated with the building has crossed the geo-fence, or that the geo-fence status of another user has changed. Each of these may be considered external stimuli. Another external stimuli may be the mobile device receiving a request for current location from a remote location, such as the building automation server 26.

FIG. 6 is a flow diagram of an illustrative method that may be carried out by the mobile device 14, having location services and executing an executable program that may be stored in the memory 58 (FIG. 5). In some cases, the mobile device 14 is a smartphone, but this is not required. At block 70, the mobile device 14 stores information pertaining to a geo-fence that is associated with a user of the mobile device 14 and that is assigned to a location (e.g. assigned to the user's building). As seen at block 72, a current location of the mobile device 14 is identified via the location services of the mobile device 14. The locating data is stored at block 74, including the current location of the mobile device 14 and one or more past locations of the mobile device 14.

As generally indicated at block 76, a current geo-fence state of the mobile device 14 is determined based on the location data in response to an internal stimuli or an external stimuli, wherein the geo-fence state is selected from at least an inside geo-fence state in which the mobile device 14 is deemed to be inside the geo-fence and an outside geo-fence state in which the mobile device 14 is deemed to be outside of the geo-fence. The internal stimuli and external stimuli may be the same as those discussed with respect to FIG. 5. A remote server, such as the building automation server 26, may be notified of the current geo-fence state, as seen at block 78.

FIG. 7 is a flow diagram showing another illustrative method that may be carried out by the mobile device 14, having location services and executing an executable program that may be stored in the memory 58 (FIG. 5). At block 70, the mobile device 14 stores information pertaining to a geo-fence that is associated with a user of the mobile device 14 and that is assigned to a location (e.g. assigned to the user's building). As seen at block 72, a current location of the mobile device 14 is identified via the location services of the mobile device 14. The locating data is stored at block 74, including the current location of the mobile device 14 and one or more past locations of the mobile device 14.

As generally indicated at block 76, a current geo-fence state of the mobile device 14 is determined based on the location data in response to an internal stimuli or an external stimuli, wherein the geo-fence state is selected from at least an inside geo-fence state in which the mobile device 14 is deemed to be inside the geo-fence and an outside geo-fence state in which the mobile device 14 is deemed to be outside of the geo-fence. A remote server, such as the building automation server 26, is notified of the current geo-fence state, as seen at block 78. In some cases, as generally indicated at block 80, a determination may be made as to whether the mobile device 14 has crossed the geo-fence by referencing the geo-fence status over time. In some embodiments, as seen at block 82, the remote server may be notified that the mobile device 14 has crossed the geo-fence if such a determination was made at block 80.

Those skilled in the art will recognize that the present disclosure may be manifested in a variety of forms other than the specific embodiments described and contemplated herein. Accordingly, departure in form and detail may be made without departing from the scope and spirit of the present disclosure as described in the appended claims. 

What is claimed is:
 1. A non-transitory computer-readable storage medium with an executable program stored thereon, wherein the executable program instructs a mobile device having location services and a communication interface for communicating with a remote server to perform the following: save information pertaining to a geo-fence, wherein the geo-fence is associated with a user of the mobile device and defines a boundary of a fixed location of a building; save a previous geo-fence state of the mobile device both locally on the mobile device and remotely on the remote server, wherein the previous geo-fence state is based on a previous location of the mobile device, and wherein the previous geo-fence state is selected from at least an inside geo-fence state in which the previous location of the mobile device is determined to be inside of the boundary of the fixed location of the building and an outside geo-fence state in which the previous location of the mobile device is determined to be outside of the boundary of the fixed location of the building; identify a current location of the mobile device via the location services; determine a current geo-fence state of the mobile device based on the current location of the mobile device, wherein the current geo-fence state is selected from at least the inside geo-fence state in which the current location of the mobile device is determined to be inside of the boundary of the fixed location of the building and the outside geo-fence state in which the mobile device is determined to be outside of the boundary of the fixed location of the building; compare the current geo-fence state with the previous geo-fence state; when the current geo-fence state fails to match the previous geo-fence state, communicate the current geo-fence state to the remote server to update the previous geo-fence state to reflect the current geo-fence state; and when the current geo-fence state matches the previous geo-fence state, refrain from communicating the current geo-fence state to the remote server.
 2. The non-transitory computer-readable storage medium of claim 1, wherein the executable program instructs the mobile device to periodically determine the current geo-fence state and compare the current geo-fence state with the previous geo-fence state.
 3. The non-transitory computer-readable storage medium of claim 1, wherein the executable program instructs the mobile device to determine the current geo-fence state and compare the current geo-fence state with the previous geo-fence state in response to an internal stimuli.
 4. The non-transitory computer-readable storage medium of claim 3, wherein the internal stimuli includes one or more of: detecting a restoration of communication via the communication interface; detecting a restoration of the location services; detecting first user input logging into the executable program; detecting a wake up condition from a force close of the executable program; detecting the mobile device exiting an airplane mode; detecting second user input turning on the location services; detecting third user input turning on geo-fencing on the mobile device; and detecting a power on condition of the mobile device.
 5. The non-transitory computer-readable storage medium of claim 1, wherein the executable program instructs the mobile device to determine the current geo-fence state and compare the current geo-fence state with the previous geo-fence state in response to an external stimuli.
 6. The non-transitory computer-readable storage medium of claim 5, wherein the external stimuli includes one or more of: the mobile device being informed via the communication interface that a suspend mode of the geo-fence has been turned off; the mobile device being informed via the communication interface that the geo-fence has been modified at a remote location; the mobile device being informed via the communication interface that another user has crossed the geo-fence; the mobile device being informed via the communication interface that any geo-fence state of the another user has changed; the mobile device being informed via the communication interface that geo-fencing has been turned on; and the mobile device receiving a request via the communication interface for the current location of the mobile device from a remote location.
 7. A system comprising a mobile device; and a remote server, wherein the mobile device saves information pertaining to a geo-fence received from the remote server, wherein the geo-fence is associated with a user of the mobile device and defines boundary of a fixed location of a building, wherein the mobile device saves a previous geo-fence state of the mobile device both locally on the mobile device and remotely on the remote server, wherein the previous geo-fence state is based on a previous location of the mobile device, wherein the previous geo-fence state is selected from at least an inside geo-fence state in which the previous location of the mobile device is determined to be inside of the boundary of the fixed location of the building and an outside geo-fence state in which the previous location of the mobile device is determined to be outside of the boundary of the fixed location of the building, wherein the mobile device identifies a current location of the mobile device via location services of the mobile device, determines a current geo-fence state of the mobile device based on the current location of the mobile device, and compares the current geo-fence state with the previous geo-fence state, wherein the current geo-fence state is selected from at least the inside geo-fence state in which the current location of the mobile device is determined to be inside of the boundary of the fixed location of the building and the outside geo-fence state in which the current location of the mobile device is determined to be outside of the boundary of the fixed location of the building, wherein, when the current geo-fence state fails to match the previous geo-fence state, the mobile device transmits the current geo-fence state to the remote server to update the previous geo-fence state to reflect the current geo-fence state, and wherein, when the current geo-fence state matches the previous geo-fence state, the mobile device refrains from transmitting the current geo-fence state to the remote server.
 8. The system of claim 7, wherein if the mobile device periodically determines the current geo-fence state and compares the current geo-fence state with the previous geo-fence state.
 9. The system of claim 7, wherein the mobile device determines the current geo-fence state and compares the current geo-fence state with the previous geo-fence state in response to an internal stimuli.
 10. The system of claim 9, wherein the internal stimuli includes one or more of: detecting a restoration of communication via a communication interface of the mobile device; detecting a restoration of the location services; detecting first user input logging into an executable program on the mobile device; detecting a wake up condition from a force close of the executable program; detecting the mobile device exiting an airplane mode; detecting second user input turning on the location services; detecting third user input turning on geo-fencing on the mobile device; and detecting a power on condition of the mobile device.
 11. The system of claim 7, wherein the mobile device determines the current geo-fence state or not and compares the current geo-fence state with the previous geo-fence state in response to an external stimuli.
 12. The system of claim 11, wherein the external stimuli includes one or more of: the mobile device being informed via a communication interface of the mobile device that a suspend mode of the geo-fence has been turned off; the mobile device being informed via the communication interface that geo-fence has been modified at a remote location; the mobile device being informed via the communication interface that another user has crossed the geo-fence; the mobile device being informed via the communication interface that any geo-fence state of the another user has changed; the mobile device being informed via the communication interface that geo-fencing has been turned on; and the mobile device receiving a request via the communication interface for the current location of the mobile device from a remote location.
 13. A mobile device comprising: a user interface; location services for determining a current location of the mobile device; a communication interface for communicating with a remote server; a memory for storing an executable program and information pertaining to a geo-fence that defines a boundary of a fixed location of a building; and a controller operatively coupled to the user interface, the location services, the communication interface, and the memory, wherein the controller is configured to: save a previous geo-fence state of the mobile device both locally on the mobile device and remotely on the remote server, wherein the previous geo-fence state is based on a previous location of the mobile device, and wherein the previous geo-fence state is selected from at least an inside geo-fence state in which the previous location of the mobile device is determined to be inside of the boundary of the fixed location of the building and an outside geo-fence state in which the previous location of the mobile device is determined to be outside of the boundary of the fixed location; identify the current location of the mobile device via the location services; determine a current geo-fence state of the mobile device based on the current location of the mobile device, wherein the current geo-fence state is selected from at least the inside geo-fence state in which the current location of the mobile device is determined to be inside of the boundary of the fixed location of the building and the outside geo-fence state in which the mobile device is determined to be outside of the boundary of the fixed location of the building; compare the current geo-fence state with the previous geo-fence state; when the current geo-fence state fails to match the previous geo-fence state, communicate the current geo-fence state to the remote server to update the previous geo-fence state to reflect the current geo-fence state; and when the current geo-fence state matches the previous geo-fence state, refrain from communicating the current geo-fence state to the remote server.
 14. The mobile device of claim 13, wherein the controller periodically determines the current geo-fence state and compares the current geo-fence state with the previous geo-fence state.
 15. The mobile device of claim 13, wherein the controller determines the current geo-fence state and compares the current geo-fence state with the previous geo-fence state in response to an internal stimuli.
 16. The mobile device of claim 15, wherein the internal stimuli includes one or more of: detecting a restoration of communication via the communication interface; detecting a restoration of the location services; detecting first user input logging into the executable program; detecting a wake up condition from a force close of the executable program; detecting the mobile device exiting an airplane mode; detecting second user input turning on the location services; detecting third user input turning on geo-fencing on the mobile device; and detecting a power on condition of the mobile device.
 17. The mobile device of claim 13, wherein the controller determines the current geo-fence state and compares the current geo-fence state with the previous geo-fence state in response to an external stimuli.
 18. The mobile device of claim 17, wherein the external stimuli includes one or more of: the mobile device being informed via the communication interface that a suspend mode of the geo-fence has been turned off; the mobile device being informed via the communication interface that the geo-fence has been modified at a remote location; the mobile device being informed via the communication interface that another user has crossed the geo-fence; the mobile device being informed via the communication interface that any geo-fence state of the another user has changed; the mobile device being informed via the communication interface that geo-fencing has been turned on; and the mobile device receiving a request via the communication interface for the current location of the mobile device from a remote location. 